<?php
$header = array(
	'STT'=>'', 
	'Mã tài nguyên'=>'',
	'Tên tài nguyên'=>'', 
	'Ghi chú'=>'',

	);
$config = array(
    'header_icon' => @$this->resource->RES_ICON,
    'header_title' => 'Quản lý '.@$this->resource->RES_NAME,
    'add_title' => 'Thêm '.@$this->resource->RES_NAME,
    'ID' => '0',
    'showEdit' => false,
    'showDelete' => false,
    'showAdd' => false,
);
if ($this->permission->check("delete", $this->resource->RES_CODE))
    $config['showDelete'] = true;

if ($this->permission->check("update", $this->resource->RES_CODE))
    $config['showEdit'] = true;
	
if ($this->permission->check("insert", $this->resource->RES_CODE))
    $config['showAdd'] = true;

$data = array();
$stt = 0;
foreach ($datas as $result) {
    $data[] = array($result->RES_ID, ++$stt, $result->RES_CODE, $result->RES_NAME, $result->RES_NOTE);
}
echo $this->atheme->table_simple($header, $data, $config);
?>

